package com.keon.jianbao.ui.viewpagerfragment;

import android.view.View;

import com.keon.jianbao.R;
import com.keon.jianbao.adapter.ViewPagerFragmentAdapter;
import com.keon.jianbao.base.BaseViewPagerFragment;
import com.keon.jianbao.enu.AppraisalStatus;
import com.keon.jianbao.ui.fragment.JianBaoListFragment;

/**
 * Created by keon on 2015/9/9.
 */
public class JianBaoViewPagerFragment extends BaseViewPagerFragment {
    @Override
    protected void onSetupTabAdapter(ViewPagerFragmentAdapter adapter) {
        String[] tabs = getResources().getStringArray(R.array.jianbao_status);
        for (int i = 0; i < tabs.length; i++) {
            int catlog = 0;
            switch (tabs[i]) {
                case "已鉴定":
                    catlog = AppraisalStatus.APPRAISALED.getStatus();
                    break;
                case "待鉴定":
                    catlog = AppraisalStatus.APPRAISAL.getStatus();
                    break;
                case "待支付":
                    catlog = AppraisalStatus.UNPAID.getStatus();
                    break;
                case "已退回":
                    catlog = AppraisalStatus.BACK.getStatus();
                    break;
            }
            adapter.addTab(tabs[i], "", JianBaoListFragment.class, getBundle(catlog));
        }
    }

    @Override
    protected void onSetupTabAdapter(ViewPagerFragmentAdapter adapter, String reponseData) {

    }

    @Override
    public void initView(View view) {

    }

    @Override
    public void initData() {

    }

    @Override
    public void onClick(View view) {

    }
}
